﻿@model BBIPM_MVCWebUI.Models.GuestResponse

@{
    Layout = null;
    ViewBag.Title = "Thanks";
}


<!DOCTYPE html>
<html>
<head>
<title>Thanks</title>
</head>
<body>
    @{
try {
WebMail.SmtpServer = "smtp.qq.com";
WebMail.SmtpPort = 25;
// WebMail.EnableSsl = true;
WebMail.UserName = "183506403@qq.com";
WebMail.Password = "bdtlwlzj";
WebMail.From = "183506403@qq.com";
WebMail.Send("13212847@qq.com", "RSVP Notification",
Model.Name + " is " + ((Model.WillAttend ?? false) ? "" : "not")
+ "attending");
} catch (Exception) {
@:<b>Sorry - we couldn't send the email to confirm your RSVP.</b>
}
}
<div>
<h1>Thank you, @Model.Name!</h1>
@if (Model.WillAttend == true) {
@:It's great that you're coming. The drinks are already in the fridge!
} else {
@:Sorry to hear that you can't make it, but thanks for letting us know.
}
</div>
</body>
</html>